package com.d3works.apps.bpm.script;

import com.d3works.apps.bpm.context.WkfContextHelper;
import java.lang.reflect.Method;
import org.camunda.bpm.engine.impl.javax.el.FunctionMapper;

public class ContextFunctionMapper extends FunctionMapper {

  @Override
  public Method resolveFunction(String prefix, String localName) {

    for (Method method : WkfContextHelper.class.getDeclaredMethods()) {
      if (method.getName().equals(localName)) {
        return method;
      }
    }

    return null;
  }
}
